import {UPDATE_USER} from '../constant'

const initState = {
    name: ''
}
export default function userReducer(preState=initState,action){
    const {type,data} = action
    switch (type) {
        case UPDATE_USER:
            return data
        default:
            return preState
    }
}